extends "../calxJS_Hide/calxJS_Hide.gd"
func _init():
	pass
func _extInit():
	._extInit()
	chaName = "小青龙"                   # 角色的名称
	attCoe.atkRan = 2                 # 攻击距离
	attCoe.maxHp = 5.5                 # 最大生命（每点代表112.5基础数值，取整数，下同）
	attCoe.atk = 4                    # 攻击力（每点代表8.5）
	attCoe.mgiAtk = 6                 # 魔法攻击（每点代表13.7）
	attCoe.def = 4                    # 物理防御（每点代表15）
	attCoe.mgiDef = 4               # 魔法防御（每点代表16.6）
	atkEff = "atk_dang" 
	xb = "木"
	lv = 3
	addSkillTxt("[升龙雷环]挥出雷环攻击敌方单体，造成150%木系魔法伤害，35%概率<麻痹>目标8秒[CD:7]")
	addSkillTxt("[龙木电流]使电流在身上流通，提升自身魔攻和魔防各10%，最高60%，4秒内免疫debuff[CD:13]")
	addSkillTxt("[晴天霹雳]召唤霹雳之雷攻击敌方全体，造成100%木系魔法伤害，额外造成目标5%当前体力值的木系魔法伤害[CD:10]")
	addCdSkill("sllh",7)
	addCdSkill("lmdl",13)
	addCdSkill("qtpl",10)

func _castCdSkill(id):
	._castCdSkill(id)
	if id == "sllh":
		var eff = sys.newEff("numHit", position, false, 1)
		eff.setText("升龙雷环", "#FF0099")
		eff.anim.set_speed_scale(0.2)
		typeHurtCha(aiCha,att.mgiAtk*1.5,Chara.HurtType.MGI,Chara.AtkType.SKILL)
		if sys.rndPer(35):
			aiCha.addBuff(bf.mabi.new(8))
	if id == "lmdl":
		var buff = hasBuff("mogong1")
		var buff1 = hasBuff("mokang1")
		if buff == null:
			addBuff(bf.mogong1.new())
		elif buff.att.mgiAtkL < 0.6:
			buff.att.mgiAtkL += 0.1
		if buff1 == null:
			addBuff(bf.mokang1.new())
		elif buff1.att.mgiDefL < 0.6:
			buff1.att.mgiDefL += 0.1
		addBuff(bf.b_gb_myfm.new(4))
	if id == "qtpl":
		var eff = sys.newEff("numHit", position, false, 1)
		eff.setText("晴天霹雳", "#FF0099")
		eff.anim.set_speed_scale(0.2)
		var chas = getAllChas(1)
		for i in chas:
			typeHurtCha(i,att.mgiAtk*1,Chara.HurtType.MGI,Chara.AtkType.SKILL)
			typeHurtCha(i,i.att.hp*0.05,Chara.HurtType.MGI,Chara.AtkType.SKILL)